Frame Callbacks Structure
When you create an AWT context associated with a session, you must pass a data structure that provides frame callback information. This data structure is defined by theJMFrameCallbacks
data type.
struct JMFrameCallbacks { UInt32 fVersion; JMSetFrameSizeProcPtr fSetFrameSize; JMFrameInvalRectProcPtr fInvalRect; JMFrameShowHideProcPtr fShowHide; JMSetTitleProcPtr fSetTitle; JMCheckUpdateProcPtr fCheckUpdate; JMReorderFrame fReorderFrame; JMSetResizeable fSetResizeable; };
Field Description
fVersion
- The version of JManager. You should set this field to
kJMVersion
.fSetFrameSize
- A pointer to a function that handles a frame sizing request. This callback function has the following type definition:
typedef void (*JMSetFrameSizeProcPtr) ( JMFrameRef frame, const Rect* newBounds);
- For more information, see the description of the application-defined function
MyResizeRequest
.fInvalRect
- A pointer to a function that handles a frame invalidation request. This callback function has the following type definition:
typedef void (*JMFrameInvalRectProcPtr) ( JMFrameRef frame, const Rect* r);
- For more information, see the description of the application-defined function
MyInvalRect
fShowHide
- A pointer to a window show/hide function. This callback function has the following type definition:
typedef void (*JMFrameShowHideProcPtr) ( JMFrameRef frame, Boolean showFrameRequested);
- For more information, see the description of the application-defined function
MyShowHide
.fSetTitle
- A pointer to a function that sets the title bar text for a frame. This callback function has the following type definition:
typedef void (*JMSetTitleProcPtr) ( JMFrameRef frame, const JMTextRef title);
- For more information, see the description of the application-defined function
MySetTitle
.fCheckUpdate
- A pointer to a function that allows the frame to be updated during an interaction (such as a mouse drag). This callback function has the following type definition:
typedef void (*JMCheckUpdateProcPtr) ( JMFrameRef frame);
- For more information, see the description of the application-defined function
MyCheckUpdate
.fReorderFrame
- A pointer to a function that changes the ordering of the frame. For example, you can bring a frame to the front or send it to the back. This callback function has the following type definition:
typedef void (*JMReorderFrame) ( JMFrameRef frame, enum ReorderRequest theRequest);
- For more information, see the description of the application-defined function
MyFrameReorder
.fSetResizeable
- A pointer to a function that sets a frame as resizeable or not. This callback has the following type definition:
typedef void (*JMSetResizeable) ( JMFrameRef frame, Boolean resizeable);
- For more information, see the description of the application-defined function
MySetResizeable
.